<?php
class UserModel extends Model {
    // 定义自动验证
    protected $_validate    =   array(
        array('username','require',"请输入用户名",1,'',4),
        array('username','',"该用户名已存在",1,'unique',4),
        array('password','require','请输入密码',1,'',4),
        array('usermail','email','请输入正确的邮箱地址',1),
        array('usermail','','该邮箱已经被使用',1,'unique',4),
        array('repass','password','两次输入的密码不一致',1,'confirm',4),
    );
}